package me.msbj;


//import me.msbj.base.MyInterceptor;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
import org.springframework.transaction.annotation.EnableTransactionManagement;


/**
 * @author Administrator
 */
@SpringBootApplication
@Configuration
@EnableTransactionManagement
@EnableJpaRepositories("me.msbj.**.repository")
public class Application {

    private static final Logger logger = LoggerFactory.getLogger(Application.class);

    /**
     * 配置认证错误过滤器
     *
     * @return
     */
//    @Bean
//    public FilterRegistrationBean myFilterRegistration() {
//        FilterRegistrationBean registration = new FilterRegistrationBean();
//        registration.setFilter(new MyInterceptor());
//        registration.addUrlPatterns("/*");
//        registration.setOrder(Ordered.HIGHEST_PRECEDENCE + 1);
//        return registration;
//    }

    public static void main(String[] args) {
        SpringApplication.run(Application.class, args);
        logger.info("Dispatch System start success");
    }
}
